<%@page import="com.google.appengine.api.datastore.Query.FilterOperator"%>
<%@ page import="java.util.List" %>
<%@ page import="com.google.appengine.api.datastore.DatastoreServiceFactory" %>
<%@ page import="com.google.appengine.api.datastore.DatastoreService" %>
<%@ page import="com.google.appengine.api.datastore.Query" %>
<%@ page import="com.google.appengine.api.datastore.Entity" %>
<%@ page import="com.google.appengine.api.datastore.FetchOptions" %>
<%@ page import="com.google.appengine.api.datastore.Key" %>
<%@ page import="com.google.appengine.api.datastore.KeyFactory" %>

		<%
		String username = request.getParameter("username");
		DatastoreService datastore = DatastoreServiceFactory.getDatastoreService();
		Key accountKey = KeyFactory.createKey("Accounts", "accountName");
		
		Query query = new Query("Account", accountKey).addFilter("username",FilterOperator.EQUAL, username);
		Entity accounts = datastore.prepare(query).asSingleEntity();
		%>
		<div id="">
			<p>
				Account for username : "<%=username %>" was created successfully!!!
			</p>
		</div>
		<div style="padding:10px; margin-bottom:20px;">
			<table class="table2">
				<thead>
					<tr>
						<th>Username</th>
						<th>Password</th>
						<th>First Name</th>
						<th>Last Name</th>
						<th>User Role</th>
						<th>Lock Status</th>
						<th>Account Key</th>
					<tr>
				</thead>
				<tbody> 
					<tr>
						<td><%= accounts.getProperty("username") %></td>
						<td><%= accounts.getProperty("password") %></td>
						<td><%= accounts.getProperty("firstName") %></td>
						<td><%= accounts.getProperty("lastName") %></td>
						<td><%= accounts.getProperty("account_type") %></td>
						<td><%= accounts.getProperty("lockStatus") %></td>
						<td><%= accounts.getKey() %></td>
					</tr>
				</tbody>
			</table>
		</div>